package com.woniuxy.woniubook.service;

import com.woniuxy.woniubook.esdao.MyBookRepository;
import com.woniuxy.woniubook.vo.EsBook;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class EsBookService {

    @Autowired
    MyBookRepository repository ;

    public List<EsBook> getBookByEs(String kw){
        return repository.findByNameOrAuthorOrTypeNameOrProviderOrDetail(kw,kw,kw,kw,kw);
    }


}
